/* indent size: 2 */

module.exports = app => {
  const DataTypes = app.Sequelize;

  const Model = app.model.define('usermoney', {
    id: {
      type: DataTypes.INTEGER(11),
      allowNull: false,
      primaryKey: true,
      autoIncrement: true,
    },
    userid: {
      type: DataTypes.STRING(64),
      allowNull: true,
    },
    name: {
      type: DataTypes.STRING(64),
      allowNull: true,
    },
    phone: {
      type: DataTypes.STRING(64),
      allowNull: true,
    },
    usertype: {
      type: DataTypes.STRING(64),
      allowNull: true,
    },
    usersource: {
      type: DataTypes.STRING(64),
      allowNull: true,
    },
    appsource: {
      type: DataTypes.STRING(64),
      allowNull: true,
    },
    property: {
      type: 'DOUBLE',
      allowNull: true,
    },
    creditavailable: {
      type: 'DOUBLE',
      allowNull: true,
    },
    frozencapital: {
      type: 'DOUBLE',
      allowNull: true,
    },
    camount: {
      type: 'DOUBLE',
      allowNull: true,
    },
    cinvestment: {
      type: 'DOUBLE',
      allowNull: true,
    },
    aincome: {
      type: 'DOUBLE',
      allowNull: true,
    },
    aloan: {
      type: 'DOUBLE',
      allowNull: true,
    },
    tpayment: {
      type: 'DOUBLE',
      allowNull: true,
    },
    balance: {
      type: 'DOUBLE',
      allowNull: true,
    },
  }, {
    tableName: 'usermoney',
  });

  Model.associate = function() {

  };

  return Model;
};
